package com.tencent.sr.iris.activity.interfaces.client.activity;

import com.tencent.sr.iris.activity.interfaces.request.acticity.*;
import com.tencent.sr.iris.activity.interfaces.response.activity.ActivityStaticResponse;
import com.tencent.sr.iris.activity.interfaces.response.activity.ActivityUserStaticResponse;
import com.tencent.sr.iris.activity.interfaces.response.activity.AwardStaticResponse;
import com.tencent.sr.iris.activity.interfaces.response.activity.LongTermAwardStaticResponse;
import com.tencent.sr.iris.activity.interfaces.response.activity.UserActivityInfoResponse;
import com.tencent.sr.iris.user.core.service.interfaces.response.user.UserLevelCountResponse;
import com.tencent.sr.rmall.common.primitive.HttpResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

@FeignClient(value = "iris-activity-core-service", contextId = "UserTaskStaticClient",
        path = "/api/v1/iris/iris-activity-core-service/task/static")
public interface UserTaskStaticClient {

    @PostMapping("longTermAward")
    HttpResult<LongTermAwardStaticResponse> longTermAward(
            @Validated @RequestBody LongTermAwardStaticRequest request);

    /**
     * 活动收益统计
     *
     * @author nixiaolin
     * @date 2023/2/15 18:08
     */
    @PostMapping("awardStatic")
    HttpResult<AwardStaticResponse> awardStatic(@Validated @RequestBody AwardStaticRequest request);

    /**
     * 查询活动周期内上级用户的下级数量
     */
    @PostMapping("lowerLevelUserCount")
    HttpResult<List<UserLevelCountResponse>> lowerLevelUserCount(
            @Validated @RequestBody LowerLevelUserCountRequest request);

    /**
     * 活动参与用户统计
     *
     * @param request
     * @return
     */
    @PostMapping("activityUserStatic")
    HttpResult<ActivityUserStaticResponse> activityUserStatic(
            @Validated @RequestBody ActivityUserStaticRequest request);

    /**
     * 用户活动信息
     * @param request
     * @return
     */
    @PostMapping("userActivityInfo")
    HttpResult<UserActivityInfoResponse> userActivityInfo(
            @Validated @RequestBody UserActivityInfoRequest request);

    /**
     * 活动参与用户统计
     *
     * @param request
     * @return
     */
    @PostMapping("activityStatic")
    HttpResult<ActivityStaticResponse> activityStatic(
            @Validated @RequestBody ActivityStaticRequest request);
}
